package amani.wechat.platform.utils;
 
import com.tencent.service.BaseService;

/**
 * 统一下单接口服务
 * @author VV
 *
 */ 
public class WebPagePayService extends BaseService{

	public WebPagePayService() throws ClassNotFoundException,
			IllegalAccessException, InstantiationException {
	     super("https://api.mch.weixin.qq.com/pay/unifiedorder");
	}
	
	 /**
     * 请求支付服务
     * @param scanPayReqData 这个数据对象里面包含了API要求提交的各种数据字段
     * @return API返回的数据
     * @throws Exception
     */
    public String request(WxPayData wxPayData) throws Exception {

        //--------------------------------------------------------------------
        //发送HTTPS的Post请求到API地址
        //--------------------------------------------------------------------
        String responseString = sendPost(wxPayData);

        return responseString;
    }

}
